package com.demo;
class Singleton {

	private static Singleton intsance = new Singleton();
	
	public static int counter1;
	
	public static int counter2 = 0;
	
	
	private Singleton() {
	
		counter1++;
		
		counter2++;
	
	}
	
	public static Singleton getInstance() {
	
		return intsance;
	
	}

}

public class Test {

	public static void main(String [] a) {
		Singleton instance = Singleton.getInstance();
		
		System.out.println("counter1 = " + Singleton.counter1 + ", counter2 = " + Singleton.counter2);
	}
	

}